package com.registration.bean;


import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

@JsonInclude(JsonInclude.Include.NON_NULL)
public class PatientBean {
    //就诊人
    private Integer patient_id;//就诊人 ID（自增）
    private Integer   user_id;//所属用户 ID（外键关联 user 表）
    private String   name;//就诊人姓名
    private String   id_card;//身份证号
    private Integer   gender;//性别（0 - 未知，1 - 男，2 - 女）
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date birth_date;//出生日期
    private String  phone;//联系电话
    private String  relationship;//与用户关系（本人、父母、子女等）
    private Integer  is_default;//是否默认就诊人（0 - 否，1 - 是）
    private Integer  status;//状态（0 - 禁用，1 - 正常）
    private Date create_time;//记录创建时间


    private Double height;//身高

    private Double weight;//体重

    private String  blood_type;//血型

    @Override
    public String toString() {
        return "PatientBean{" +
                "patient_id=" + patient_id +
                ", user_id=" + user_id +
                ", name='" + name + '\'' +
                ", id_card='" + id_card + '\'' +
                ", gender=" + gender +
                ", birth_date=" + birth_date +
                ", phone='" + phone + '\'' +
                ", relationship='" + relationship + '\'' +
                ", is_default=" + is_default +
                ", status=" + status +
                ", create_time=" + create_time +
                ", height=" + height +
                ", weight=" + weight +
                ", blood_type='" + blood_type + '\'' +
                ", update_time=" + update_time +
                '}';
    }

    public Double getHeight() {
        return height;
    }

    public void setHeight(Double height) {
        this.height = height;
    }

    public Double getWeight() {
        return weight;
    }

    public void setWeight(Double weight) {
        this.weight = weight;
    }

    public String getBlood_type() {
        return blood_type;
    }

    public void setBlood_type(String blood_type) {
        this.blood_type = blood_type;
    }

    private Date  update_time;//记录更新时间


    public Integer getPatient_id() {
        return patient_id;
    }

    public void setPatient_id(Integer patient_id) {
        this.patient_id = patient_id;
    }

    public Integer getUser_id() {
        return user_id;
    }

    public void setUser_id(Integer user_id) {
        this.user_id = user_id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getId_card() {
        return id_card;
    }

    public void setId_card(String id_card) {
        this.id_card = id_card;
    }

    public Integer getGender() {
        return gender;
    }

    public void setGender(Integer gender) {
        this.gender = gender;
    }

    public Date getBirth_date() {
        return birth_date;
    }

    public void setBirth_date(Date birth_date) {
        this.birth_date = birth_date;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getRelationship() {
        return relationship;
    }

    public void setRelationship(String relationship) {
        this.relationship = relationship;
    }

    public Integer getIs_default() {
        return is_default;
    }

    public void setIs_default(Integer is_default) {
        this.is_default = is_default;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getCreate_time() {
        return create_time;
    }

    public void setCreate_time(Date create_time) {
        this.create_time = create_time;
    }

    public Date getUpdate_time() {
        return update_time;
    }

    public void setUpdate_time(Date update_time) {
        this.update_time = update_time;
    }
}
